package com.schoolcloud.api.client.front;

import com.schoolcloud.common.model.UserInfo;
import com.schoolcloud.common.model.FrontUserLoginDTO;
import com.schoolcloud.common.model.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

@FeignClient(value = "sc-front",path = "/front/user",contextId = "frontUserClient")
public interface FrontUserClient {
    @GetMapping("/info/{userId}")
    R<UserInfo> getFroUserInfoById(@PathVariable String userId);
    @GetMapping
    public R<UserInfo> getUser(UserInfo froUser) ;
    @PostMapping("/login")
    public R<UserInfo> login(@RequestBody FrontUserLoginDTO froUser) ;
    @PostMapping
    public R<String> saveUser(@RequestBody UserInfo froUser) ;

}
